/*
 * Copyright (c) 2022 Kirky
 * Licensed under the Open Software Licence, Version 3.0 (the "License");
 * you may not use this file except in compliance with the License.
 * You may obtain a copy of the License at
 *
 *     https://opensource.org/licenses/osl-3.0.php
 *
 * Unless required by applicable law or agreed to in writing, software
 * distributed under the License is distributed on an "AS IS" BASIS,
 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
 * See the License for the specific language governing permissions and
 * limitations under the License.
 */
package com.lingeringdream.luciole.model.entity;

import ohos.data.orm.OrmObject;
import ohos.data.orm.annotation.Column;
import ohos.data.orm.annotation.Entity;
import ohos.data.orm.annotation.PrimaryKey;

/**
 * 隐私清单
 *
 * @author Kirky
 * @version 1.0
 * @date 2022/5/5
 */
@Entity(tableName = "privates")
public class Privates extends OrmObject {

    @PrimaryKey(autoGenerate = true)
    private Integer id;

    @Column(name = "name", notNull = true, unique = true, index = true)
    private String name;

    /**
     * 使用目的
     */
    @Column(name = "purpose", notNull = true)
    private String purpose;

    /**
     * 隐私类别
     * 0：用户信息
     * 1；系统权限
     */
    @Column(name = "type", notNull = true)
    private Integer type;

    /**
     * 最后一次调用时间
     */
    @Column(name = "last", notNull = true)
    private Long last;

    /**
     * 使用次数
     */
    @Column(name = "count", notNull = true)
    private Integer count;

    public Integer getId() {
        return id;
    }

    public void setId(Integer id) {
        this.id = id;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getPurpose() {
        return purpose;
    }

    public void setPurpose(String purpose) {
        this.purpose = purpose;
    }

    public Integer getType() {
        return type;
    }

    public void setType(Integer type) {
        this.type = type;
    }

    public Long getLast() {
        return last;
    }

    public void setLast(Long last) {
        this.last = last;
    }

    public Integer getCount() {
        return count;
    }

    public void setCount(Integer count) {
        this.count = count;
    }
}
